package com.ht.web.aduit;

import com.ht.bean.aduit.Aduitlog;
import com.ht.bean.aduit.Aduitmodel;
import com.ht.bean.emp.Empinfo;
import com.ht.bean.json.JsonData;
import com.ht.service.aduit.AssessService;
import com.ht.util.Pager;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import javax.annotation.Resource;
import java.util.List;

/**
 * @author 王金宝
 * @date 2020/6/24 10:08
 */
@Controller
@RequestMapping("assess")
public class AssessController {
    @Resource
    private JsonData jsonData;
    @Resource
    private AssessService assessService;
    //去到考核统计管理页面
    @RequestMapping("assesslist")
    public String modellist(){
        return "aduit/assesslist";
    }

    /**
     * @param limit
     * @param page
     * @return
     * 获取考核入录列表信息
     */
    @RequestMapping("listdata")
    @ResponseBody
    public JsonData depList(int limit , int page){
        Pager pager = new Pager();
        pager.setPageSize(limit);
        pager.setCurrPage(page);
        jsonData.setCount(assessService.getTotalRow());
        jsonData.setData(assessService.allPageAssess(pager));
        return jsonData;
    }


}
